﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.Web.UI;
using System.Web.UI.WebControls;
using Box.BL;
using Microsoft.Practices.Unity;

namespace Box.Cliente
{
    public partial class _Default : Page
    {
        [Dependency]
        public IProductoBL prodService { get; set; }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                
            }
       
        }
        [WebMethod]
        public void ContarProductos()
        {
            var cantidad = 0;

            cantidad = prodService.ProductoBajoStock();

            

            if (cantidad > 0)
            {
                ScriptManager.RegisterStartupScript(this.lblAction, GetType(), "lblAction", "diHola();", true);
            }
            else
            {
                lblAction.Text = "";
            }
        }
    }
}